package thesis.filesharing.dao;

import java.util.List;

import thesis.filesharing.common.valueobjects.SearchStudentValueObject;
import thesis.filesharing.model.Clazz;
import thesis.filesharing.model.Student;

import com.google.appengine.api.datastore.Key;

public interface StudentDAO {
	
	public Student findStudentById(String studentId);
	public Student findStudentByEmail(String studentEmail);
	public Student findStudentByKey(Key studentKey);
	public Student saveStudent(Student student);
	public List<Student> listStudents(int page, int pageSize);
	public int countStudents();
	public void deleteStudent(Key studentKey);
	public Student updateStudent(Student student);
	public boolean isEmailDuplicatedWithOrtherStudent(String studentEmail, Key studentKey);
	public int countFoundStudents(SearchStudentValueObject searchObj);
	public List<Student> searchStudent(SearchStudentValueObject searchObj, int page, int pageSize);
	public List<Student> listStudentsInClass(Key classKey, int page, int pageSize);
	public int countStudentsInClass(Key classKey);
	public List<Clazz> listClassesStudentRegistered(String studentId, Integer semester);
	public boolean checkStudentRegisteredClass(String studentId, Key classKey);
}
